﻿<%@ Page Title="" Language="C#" MasterPageFile="~/SiteLayout.Master" AutoEventWireup="true" CodeBehind="offer_cars.aspx.cs" Inherits="carportal.offer_cars" culture="auto" meta:resourcekey="PageResource1" uiculture="auto" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <style type="text/css">
        .floafleft
        {
            float:left;
        }
        .style14
        {
            width: 192px;
        }
        .style16
        {
            width: 176px;
        }
        .style17
        {
            width: 94px;
        } 
        .stylec1
        {
           
        }
        .newStyle1
        {color: rgb(31, 73, 125); font-family: Calibri, sans-serif; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; background-color: rgba(255, 255, 255, 0.917969); display: inline !important; float: none;  
                           
        }
        .style19
        {
            width: 228px;
            color: rgb(31, 73, 125);
            font-family: Calibri, sans-serif;
            font-size: 15px;
            font-style: normal;
            font-variant: normal;
            font-weight: normal;
            letter-spacing: normal;
            line-height: normal;
            background-color: rgba(255, 255, 255, 0.917969);
        }
        .style23
        {
            width: 344px;
            text-align: left;
        }
        .margleft10
        {
            margin-left: 10px;
        }
        .style25
        {
            color: rgb(31, 73, 125);
            font-family: Calibri, sans-serif;
            font-size: 15px;
            font-style: normal;
            font-variant: normal;
            font-weight: normal;
            letter-spacing: normal;
            line-height: normal;
            background-color: rgba(255, 255, 255, 0.917969);
        }
        .style26
        {
            width: 537px;
            color: rgb(31, 73, 125);
            font-family: Calibri, sans-serif;
            font-size: 15px;
            font-style: normal;
            font-variant: normal;
            font-weight: normal;
            letter-spacing: normal;
            line-height: normal;
            background-color: rgba(255, 255, 255, 0.917969);
        }
        .style27
        {
            width: 128px;
        }
        </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    
                <asp:UpdatePanel ID="UpdatePanel1" runat="server">
    <ContentTemplate>

    <asp:Panel ID="Panel1" runat="server" Width="747px" CssClass="margleft10" 
               BorderStyle="Solid"  >
               <br />
     <asp:Panel ID="Panel11" runat="server" Width="720px"  
           BorderStyle="Groove" BackColor="White" BorderWidth="2px">
              <strong>&nbsp;&nbsp; ENTER </strong> <span class="color-3" style="outline: 0;">
              <strong>CAR DETAILS:</strong></span><hr />  
        <table class="style1" style="font-size: small; font-family: Verdana; height: 299px; width: 95%; margin-left: 10px;">
            
            <tr>
                <td  colspan="2">
                    <asp:Panel ID="Panel4" runat="server" CssClass="floafleft">
                        MAKE:<br />
                        <asp:DropDownList ID="DropDownListMake" runat="server" 
                            AppendDataBoundItems="True" AutoPostBack="True" DataSourceID="SqlDataSource1" 
                            DataTextField="make_name" DataValueField="id" 
                            meta:resourcekey="DropDownList1Resource1" oninit="DropDownList1_Init" 
                            onload="DropDownList1_Load" Width="200px">
                        </asp:DropDownList>
                    </asp:Panel>
                    <div style="float:left;width:120px" > &nbsp; </div>
                    <asp:Panel ID="Panel5" runat="server" CssClass="floafleft" >
                        MODEL:<br />
                        <asp:DropDownList ID="DropDownListModel" runat="server" 
                            DataSourceID="SqlDataSource2" DataTextField="model" DataValueField="id" 
                            meta:resourcekey="DropDownList2Resource1" Width="200px">
                        </asp:DropDownList>
                    </asp:Panel>
                    <br />
                </td>
                <td  colspan="2">
                    &nbsp;</td>
                <td>
                    &nbsp;</td>
            </tr>
            <tr>
                <td class="style19" colspan="2">
                    <span style="color: rgb(31, 73, 125); font-family: Calibri, sans-serif; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; background-color: rgba(255, 255, 255, 0.917969); display: inline !important; float: none; ">
                    VEHICLE TYPE:<br /> </span>
                    <asp:DropDownList ID="DropDownListVechiletype" runat="server" 
                        DataSourceID="SqlDataSource3" DataTextField="vehicletype" 
                        DataValueField="id" meta:resourcekey="DropDownList6Resource1" 
                        Width="200px">
                    </asp:DropDownList>
                    <br />
                </td>
                <td class="newStyle1" colspan="2">
                    <br />
                </td>
                <td>
                    &nbsp;</td>
            </tr>
            <tr>
                <td class="style19" colspan="2">
                    <asp:Panel ID="Panel6" runat="server" CssClass="floafleft">
                    KM<br />
                    <asp:TextBox ID="TextBoxMillage" runat="server" 
                        meta:resourcekey="TextBox1Resource1" Width="200px"></asp:TextBox>
                        </asp:Panel>
                        <div style="float:left;width:120px" > &nbsp; </div>
                    
                    <asp:Panel ID="Panel7" runat="server" CssClass="floafleft">
                    YEAR<br />
                        <asp:DropDownList ID="DropDownListFirstregyear" runat="server" 
                            meta:resourcekey="DropDownList3Resource1">
                            <asp:ListItem meta:resourcekey="ListItemResource1">2012</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource2">2011</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource3">2010</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource4">2009</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource5">2008</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource6">2007</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource7">2006</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource8">2005</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource9">2004</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource10">2003</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource11">2002</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource12">2001</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource13">2000</asp:ListItem>
                        </asp:DropDownList>
                    </asp:Panel> 
                    <div style="float:left;width:60px" > &nbsp;</div>
                        <asp:Panel ID="Panel8" runat="server" CssClass="floafleft">
                     MONTH<br />
                    <asp:DropDownList ID="DropDownList4" runat="server" 
                        meta:resourcekey="DropDownList4Resource1">
                        <asp:ListItem meta:resourcekey="ListItemResource14">Jan</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource15">Feb</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource16">Mar</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource17">Apr</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource18">May</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource19">Jun</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource20">Jul</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource21">Aug</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource22">Sep</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource23">Oct</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource24">Nov</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource25">Dec</asp:ListItem>
                    </asp:DropDownList></asp:Panel>
                    
                    
                </td>
                <td class="newStyle1">
                    &nbsp;</td>
                <td class="newStyle1">
                   
                </td>
                <td>
                    &nbsp;</td>
            </tr>
            <tr>
                <td class="style25">
                    CYLINDRE<br />
                    <asp:DropDownList ID="DropDownList5" runat="server" Width="60px">
                        <asp:ListItem>4</asp:ListItem>
                        <asp:ListItem>6</asp:ListItem>
                        <asp:ListItem>8</asp:ListItem>
                    </asp:DropDownList>
                </td>
                <td class="style26">
                    &nbsp;POWER<br />
                    <asp:TextBox ID="TextBoxenginesize" runat="server" 
                        meta:resourcekey="TextBox3Resource1" Width="120px"></asp:TextBox>
                </td>
                <td class="newStyle1" colspan="2">
                    &nbsp;</td>
                <td>
                    &nbsp;</td>
            </tr>
            <tr>
                <td class="style25" colspan="2">
                    
                    GEARBOX<br />
                    <asp:DropDownList ID="DropDownListGearbox" runat="server" 
                        meta:resourcekey="DropDownList5Resource1" Width="200px">
                        <asp:ListItem meta:resourcekey="ListItemResource26">Manual</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource27">Automatic</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource28">TipTronic</asp:ListItem>
                        <asp:ListItem meta:resourcekey="ListItemResource29">Other</asp:ListItem>
                    </asp:DropDownList>
                    
                </td>
                <td class="newStyle1" colspan="2">
                    &nbsp;</td>
                <td>
                    &nbsp;</td>
            </tr>
            <tr>
                <td class="style19" colspan="2">
                    FUEL:
                    <asp:RadioButton ID="RadioButton1" runat="server" GroupName="FuelType" 
                        meta:resourcekey="RadioButton1Resource1" Text="Diesel" />
                    &nbsp;<asp:RadioButton ID="RadioButton2" runat="server" GroupName="FuelType" 
                        meta:resourcekey="RadioButton2Resource1" Text="Petrol" />
                    <asp:RadioButton ID="RadioButton3" runat="server" GroupName="FuelType" 
                        meta:resourcekey="RadioButton3Resource1" Text="Gas" />
                </td>
                <td class="newStyle1" colspan="2">
                    &nbsp;</td>
                <td>
                    &nbsp;</td>
            </tr>
            </table><br /></asp:Panel>
         <br />
            <asp:Panel ID="Panel12" runat="server" Width="720px"  
           BorderStyle="Groove" BackColor="White" BorderWidth="2px">
            <strong>&nbsp;&nbsp; ENTER </strong> <span class="color-3" style="outline: 0;">
              <strong>CAR FEATURES:</strong></span><hr />  
               <table class="style1" style="margin-left: 10px;" >
                 
                <tr>
                    <td class="style16">
                        SEAT<br />
                        <asp:DropDownList ID="DropDownListSeatcount" runat="server" 
                            meta:resourcekey="DropDownList9Resource1">
                            <asp:ListItem meta:resourcekey="ListItemResource33">2</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource34">4</asp:ListItem>
                            <asp:ListItem>5</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource35">6</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource36">7</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource37">8</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource38">More</asp:ListItem>
                        </asp:DropDownList>
                    </td>
                    <td colspan="2">
                        <span class="newStyle1">DOOR<br /> </span>
                        <asp:DropDownList ID="DropDownListDorrCount" runat="server" 
                            meta:resourcekey="DropDownList10Resource1">
                            <asp:ListItem meta:resourcekey="ListItemResource39">2</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource40">3</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource41">4</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource42">5</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource43">6</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource44">7</asp:ListItem>
                        </asp:DropDownList>
                    </td>
                    <td>
                        CLIMATE CONTROL:<br />
                        <asp:DropDownList ID="DropDownListClima" runat="server" 
                            meta:resourcekey="DropDownList8Resource1">
                            <asp:ListItem meta:resourcekey="ListItemResource30" Value="0">No</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource31" Selected="True" Value="1">Automatic</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource32" Value="2">Manual</asp:ListItem>
                        </asp:DropDownList>
                    </td>
                </tr>
                <tr>
                    <td class="style16">
                        <span style="color: rgb(31, 73, 125); font-family: Calibri, sans-serif; font-size: 15px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; background-color: rgba(255, 255, 255, 0.917969); display: inline !important; float: none; ">
                        COLOUR:<br /> </span>
                        <asp:DropDownList ID="DropDownListColor" runat="server" 
                            meta:resourcekey="DropDownList11Resource1">
                            <asp:ListItem meta:resourcekey="ListItemResource45">Beige</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource46">Black</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource47">Blue</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource48">Brown</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource49">Gold</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource50">Green</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource51">Grey</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource52">Orange</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource53">Purple</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource54">Red</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource55">Silver</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource56">White</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource57">Yellow</asp:ListItem>
                            <asp:ListItem meta:resourcekey="ListItemResource58">Other</asp:ListItem>
                        </asp:DropDownList>
                    </td>
                    <td class="style17">
                        <asp:CheckBox ID="CheckBox1" runat="server" 
                            meta:resourcekey="CheckBox1Resource1" Text="Metallic" />
                    </td>
                    <td class="style27">
                        &nbsp;</td>
                    <td>
                        &nbsp;</td>
                </tr>
                <tr>
                    <td class="style16">
                        <asp:CheckBox ID="FCheckBox1" runat="server" Text="Auxiliary heating" 
                            meta:resourcekey="FCheckBox1Resource1" /><br />
                        <asp:CheckBox ID="FCheckBox2" runat="server" Text="Central locking" 
                            meta:resourcekey="FCheckBox2Resource1" /><br />
                        <asp:CheckBox ID="FCheckBox3" runat="server" Text="Cruise control " 
                            meta:resourcekey="FCheckBox3Resource1" /><br />
                        <asp:CheckBox ID="FCheckBox4" runat="server" Text="Electric heated seats" 
                            meta:resourcekey="FCheckBox4Resource1" /><br />
                        <asp:CheckBox ID="FCheckBox5" runat="server" Text="Electric windows" 
                            meta:resourcekey="FCheckBox5Resource1" /><br />
                        <asp:CheckBox ID="FCheckBox6" runat="server" Text="Leather seats" 
                            meta:resourcekey="FCheckBox6Resource1" /><br />
                        <asp:CheckBox ID="FCheckBox7" runat="server" Text="Parking sensors " 
                            meta:resourcekey="FCheckBox7Resource1" /><br />
                    </td>
                    <td colspan="2">
                        <asp:CheckBox ID="FCheckBox8" runat="server" Text="Power Assisted Steering" 
                            meta:resourcekey="FCheckBox8Resource1" />
                        <br />
                        <asp:CheckBox ID="FCheckBox9" runat="server" Text="Sunroof" 
                            meta:resourcekey="FCheckBox9Resource1" />
                        <br />
                        <asp:CheckBox ID="FCheckBox10" runat="server" Text="Four wheel drive" 
                            meta:resourcekey="FCheckBox10Resource1" />
                        <br />
                        <asp:CheckBox ID="FCheckBox11" runat="server" Text="Immobilizer" 
                            meta:resourcekey="FCheckBox11Resource1" />
                        <br />
                        <asp:CheckBox ID="FCheckBox13" runat="server" Text="Xenon headlights" 
                            meta:resourcekey="FCheckBox13Resource1" />
                        <br />
                        <asp:CheckBox ID="FCheckBox14" runat="server" Text="ABS" 
                            meta:resourcekey="FCheckBox14Resource1" />
                        <br />
                        <asp:CheckBox ID="FCheckBox15" runat="server" Text="ESP" 
                            meta:resourcekey="FCheckBox15Resource1" />
                    </td>
                    <td>
                        &nbsp;</td>
                </tr>
                <tr>
                    <td class="style16">
                        &nbsp;</td>
                    <td colspan="2">
                        &nbsp;</td>
                    <td>
                        &nbsp;</td>
                </tr>
                <tr>
                    <td class="style16">
                        &nbsp;</td>
                    <td colspan="2">
                        <asp:Button ID="Button4" runat="server" BorderStyle="Solid" 
                            onclick="Button4_Click" Text="Next to Photos&gt;" 
                            meta:resourcekey="Button4Resource1" BorderColor="#FF3300" 
                            CssClass="navbutton" />
                    </td>
                    <td>
                        &nbsp;</td>
                </tr>
            </table>
           </asp:Panel>
         </asp:Panel>
        <asp:Panel ID="Panel2" runat="server" 
            meta:resourcekey="Panel2Resource1">

        </asp:Panel>
        <br />
        
        <asp:Panel ID="Panel3" runat="server" Visible="False" CssClass="margleft10"  >

        <asp:Panel ID="Panel10" runat="server" Width="720px"   
           BorderStyle="Groove" BackColor="White" BorderWidth="2px">
              <strong>&nbsp;&nbsp; CAR </strong> <span class="color-3" style="outline: 0;">
              <strong>DESCRIPTION</strong></span><hr />  
      <table>
            <tr><td class="style23" valign="middle" align="center"><B>&nbsp;&nbsp; PLEASE WRITE A SHORT 
                DESCRIPTION</B> </td><td>
                <asp:TextBox ID="TextBoxDescription" runat="server" Height="161px" TextMode="MultiLine" 
                    Width="360px"></asp:TextBox></td></tr></table>
 
 </asp:Panel>
 <br />
 <asp:Panel ID="Panel9" runat="server" Width="720px" 
           BorderStyle="Groove" BackColor="White" BorderWidth="2px">
              <strong>&nbsp;&nbsp; UPLOAD </strong> <span class="color-3" style="outline: 0;">
              <strong>CAR PICTURES</strong></span><hr />  
        <table class="style1" style="margin-left: 10px;">
               
                <tr>
                    <td>
                        <asp:FileUpload ID="FileUpload1" runat="server" accept="image/gif, image/jpeg" 
                            meta:resourcekey="FileUpload1Resource1" />
                    </td>
                    <td>
                        &nbsp;</td>
                </tr>
                <tr>
                    <td>
                        <asp:FileUpload ID="FileUpload2" runat="server" 
                            meta:resourcekey="FileUpload2Resource1" />
                    </td>
                    <td>
                        &nbsp;</td>
                </tr>
                <tr>
                    <td>
                        <asp:FileUpload ID="FileUpload3" runat="server" 
                            meta:resourcekey="FileUpload3Resource1" />
                    </td>
                    <td>
                        &nbsp;</td>
                </tr>
                <tr>
                    <td>
                        <asp:FileUpload ID="FileUpload4" runat="server" 
                            meta:resourcekey="FileUpload4Resource1" />
                    </td>
                    <td>
                        &nbsp;</td>
                </tr>
                <tr>
                    <td>
                        <asp:FileUpload ID="FileUpload5" runat="server" 
                            meta:resourcekey="FileUpload5Resource1" />
                    </td>
                    <td>
                        &nbsp;</td>
                </tr>
                <tr>
                    <td>
                        <asp:Button ID="Button5" runat="server" BorderStyle="Solid" 
                            onclick="Button5_Click" Text="&lt; Back to Features" 
                            meta:resourcekey="Button5Resource1" CssClass="navbutton" />
                        <asp:Button ID="Button6" runat="server" meta:resourcekey="Button6Resource1" 
                            onclick="Button6_Click" Text="Review and Submit" />
                    </td>
                    <td>
                        &nbsp;</td>
                </tr>
            </table>
 
 </asp:Panel>
  </asp:Panel>
       
        <br />&nbsp;<br />
    </ContentTemplate>
     <Triggers>
     <asp:PostBackTrigger   ControlID="Button6" />
     </Triggers>
</asp:UpdatePanel>
           
            <table style="visibility:hidden"> 
            <tr>
                <td class="textEntry" colspan="4">
                    Price:
                    <asp:TextBox ID="TextBoxPrice" runat="server" 
                        meta:resourcekey="TextBox2Resource1"></asp:TextBox>
                </td>
                <td>
                    &nbsp;</td>
            </tr>
            <tr>
                <td class="style19" colspan="2">
                    Location Country:<br />
                    <asp:DropDownList ID="DropDownListCountrycodes" runat="server" 
                        DataSourceID="SqlDataSource4" DataTextField="countryname" DataValueField="id" 
                        Width="144px"  onload="DropDownList7_Load" 
                        AppendDataBoundItems="True" meta:resourcekey="DropDownList7Resource1" 
                        oninit="DropDownList7_Init" >
                       
                    </asp:DropDownList>
                </td>
                <td class="style14" colspan="2">
                    Location City:<br />
                    <asp:TextBox ID="TextBoxCity" runat="server" 
                        meta:resourcekey="TextBox4Resource1"></asp:TextBox>
                </td>
                <td>
                    &nbsp;</td>
            </tr>
            <tr>
                <td class="style19" colspan="2">
                    &nbsp;</td>
                <td class="style14" colspan="2">
                    &nbsp;</td>
                <td>
                    &nbsp;</td>
            </tr>
        </table>
        <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
            ConnectionString="<%$ ConnectionStrings:bestgifts4usConnectionString %>" 
            SelectCommand="SELECT [id], [make_name] FROM [carportal_make]">
        </asp:SqlDataSource>
        <asp:SqlDataSource ID="SqlDataSource2" runat="server" 
            ConnectionString="<%$ ConnectionStrings:bestgifts4usConnectionString %>" 
            
            
                    SelectCommand="SELECT [id], [make_id], [model] FROM [carportal_model] WHERE ([make_id] = @make_id)" 
                    onselecting="SqlDataSource2_Selecting">
            <SelectParameters>
                <asp:ControlParameter ControlID="DropDownListMake" Name="make_id" 
                    PropertyName="SelectedValue" Type="Int32" />
            </SelectParameters>
        </asp:SqlDataSource>
                <asp:SqlDataSource ID="SqlDataSource3" runat="server" 
                    ConnectionString="<%$ ConnectionStrings:bestgifts4usConnectionString %>" 
                    SelectCommand="SELECT [id], [vehicletype] FROM [carportal_vehicletypes] ORDER BY [id] DESC">
                </asp:SqlDataSource>
                <asp:SqlDataSource ID="SqlDataSource4" runat="server" 
                    ConnectionString="<%$ ConnectionStrings:bestgifts4usConnectionString %>" 
                    SelectCommand="SELECT [id], [countrycode], [countryname] FROM [carportal_countries]">
                </asp:SqlDataSource>
                <asp:SqlDataSource ID="SqlDataSourceNewCar" runat="server" 
                    ConnectionString="<%$ ConnectionStrings:bestgifts4usConnectionString %>" 
                    DeleteCommand="DELETE FROM [carportal_cars] WHERE [id] = @id" 
                    InsertCommand="INSERT INTO [carportal_cars] ([user_id], [make], [model], [model_by_user], [car_type], [engine_power], [first_reg_date], [millage_km], [fuel_type], [gearbox], [price], [country_code], [location_city], [climate_control], [seat_count], [color], [door_count], [Auxiliary_heating], [Central_locking], [Cruise_control], [Electric_heated], [Electric_windows], [Leather_seats], [Parking_sensors], [Power_Steering], [Sunroof], [Four_wheel_drive], [Immobilizer], [Xenon_headlights], [ABS], [ESP], [user_comments]) VALUES (@user_id, @make, @model, @model_by_user, @car_type, @engine_power, @first_reg_date, @millage_km, @fuel_type, @gearbox, @price, @country_code, @location_city, @climate_control, @seat_count, @color, @door_count, @Auxiliary_heating, @Central_locking, @Cruise_control, @Electric_heated, @Electric_windows, @Leather_seats, @Parking_sensors, @Power_Steering, @Sunroof, @Four_wheel_drive, @Immobilizer, @Xenon_headlights, @ABS, @ESP, @user_comments);
SELECT  @NewCarID = SCOPE_IDENTITY();
" 
                    SelectCommand="SELECT * FROM [carportal_cars]" 
                    
                    
                    
                    
                    UpdateCommand="UPDATE [carportal_cars] SET [user_id] = @user_id, [make] = @make, [model] = @model, [model_by_user] = @model_by_user, [car_type] = @car_type, [engine_power] = @engine_power, [first_reg_date] = @first_reg_date, [millage_km] = @millage_km, [fuel_type] = @fuel_type, [gearbox] = @gearbox, [price] = @price, [country_code] = @country_code, [location_city] = @location_city, [climate_control] = @climate_control, [seat_count] = @seat_count, [color] = @color, [door_count] = @door_count, [Auxiliary_heating] = @Auxiliary_heating, [Central_locking] = @Central_locking, [Cruise_control] = @Cruise_control, [Electric_heated] = @Electric_heated, [Electric_windows] = @Electric_windows, [Leather_seats] = @Leather_seats, [Parking_sensors] = @Parking_sensors, [Power_Steering] = @Power_Steering, [Sunroof] = @Sunroof, [Four_wheel_drive] = @Four_wheel_drive, [Immobilizer] = @Immobilizer, [Xenon_headlights] = @Xenon_headlights, [ABS] = @ABS, [ESP] = @ESP, [user_comments] = @user_comments WHERE [id] = @id" 
                    oninserted="SqlDataSourceNewCar_Inserted" 
                    
                    ProviderName="<%$ ConnectionStrings:bestgifts4usConnectionString.ProviderName %>">
                    <DeleteParameters>
                        <asp:Parameter Name="id" Type="Int32" />
                    </DeleteParameters>
                     <InsertParameters>
                        <asp:ControlParameter ControlID="DropDownListMake" Name="make" 
                            PropertyName="SelectedValue" Type="Int32" />
                        <asp:ControlParameter ControlID="DropDownListModel" Name="model" 
                            PropertyName="SelectedValue" Type="Int32" />
                        <asp:Parameter Name="model_by_user" Type="String" />
                        <asp:ControlParameter ControlID="DropDownListVechiletype" Name="car_type" 
                            PropertyName="SelectedValue" Type="String" />
                        <asp:ControlParameter ControlID="TextBoxenginesize" Name="engine_power" 
                            PropertyName="Text" Type="String" />
                         <asp:ControlParameter ControlID="DropDownListFirstregyear" 
                             Name="first_reg_date" PropertyName="SelectedValue" Type="String" />
                        <asp:ControlParameter ControlID="TextBoxMillage" Name="millage_km" 
                            PropertyName="Text" Type="String" />
                        <asp:Parameter Name="fuel_type" Type="String" />
                        <asp:ControlParameter ControlID="DropDownListGearbox" Name="gearbox" 
                            PropertyName="SelectedValue" Type="String" />
                        <asp:ControlParameter ControlID="TextBoxPrice" Name="price" PropertyName="Text" 
                            Type="Decimal" />
                        <asp:ControlParameter ControlID="DropDownListCountrycodes" Name="country_code" 
                            PropertyName="SelectedValue" Type="String" />
                         <asp:ControlParameter ControlID="DropDownListClima" Name="climate_control" 
                            PropertyName="SelectedValue" Type="String" />
                        <asp:ControlParameter ControlID="DropDownListSeatcount" Name="seat_count" 
                            PropertyName="SelectedValue" Type="Int32" />
                        <asp:ControlParameter ControlID="DropDownListColor" Name="color" 
                            PropertyName="SelectedValue" Type="String" />
                        <asp:ControlParameter ControlID="DropDownListDorrCount" Name="door_count" 
                            PropertyName="SelectedValue" Type="Int32" />
                        <asp:ControlParameter ControlID="FCheckBox1" Name="Auxiliary_heating" 
                            PropertyName="Checked" Type="Int16" /> 
                         <asp:SessionParameter Name="user_id" SessionField="UserID" />
                         <asp:ControlParameter ControlID="TextBoxCity" Name="location_city" 
                             PropertyName="Text" />
                         <asp:ControlParameter ControlID="FCheckBox2" Name="Central_locking" 
                             PropertyName="Checked" />
                         <asp:ControlParameter ControlID="FCheckBox3" Name="Cruise_control" 
                             PropertyName="Checked" />
                         <asp:ControlParameter ControlID="FCheckBox4" Name="Electric_heated" 
                             PropertyName="Checked" />
                         <asp:ControlParameter ControlID="FCheckBox5" Name="Electric_windows" 
                             PropertyName="Checked" />
                         <asp:ControlParameter ControlID="FCheckBox6" Name="Leather_seats" 
                             PropertyName="Checked" />
                         <asp:ControlParameter ControlID="FCheckBox7" Name="Parking_sensors" 
                             PropertyName="Checked" />
                         <asp:ControlParameter ControlID="FCheckBox8" Name="Power_Steering" 
                             PropertyName="Checked" />
                         <asp:ControlParameter ControlID="FCheckBox9" Name="Sunroof" 
                             PropertyName="Checked" />
                         <asp:ControlParameter ControlID="FCheckBox10" Name="Four_wheel_drive" 
                             PropertyName="Checked" />
                         <asp:ControlParameter ControlID="FCheckBox11" Name="Immobilizer" 
                             PropertyName="Checked" />
                         <asp:ControlParameter ControlID="FCheckBox13" Name="Xenon_headlights" 
                             PropertyName="Checked" />
                         <asp:ControlParameter ControlID="FCheckBox14" Name="ABS" 
                             PropertyName="Checked" />
                         <asp:ControlParameter ControlID="FCheckBox15" Name="ESP" 
                             PropertyName="Checked" />
                         <asp:ControlParameter ControlID="TextBoxDescription" Name="user_comments" 
                             PropertyName="Text" />
                         <asp:Parameter Direction="Output" Name="NewCarID" Type="Int32" />
                    </InsertParameters>
                    <UpdateParameters>
                        <asp:Parameter Name="user_id" Type="Int32" />
                        <asp:Parameter Name="make" Type="Int32" />
                        <asp:Parameter Name="model" Type="Int32" />
                        <asp:Parameter Name="model_by_user" Type="String" />
                        <asp:Parameter Name="car_type" Type="String" />
                        <asp:Parameter Name="engine_power" Type="String" />
                        <asp:Parameter Name="first_reg_date" Type="String" />
                        <asp:Parameter Name="millage_km" Type="String" />
                        <asp:Parameter Name="fuel_type" Type="String" />
                        <asp:Parameter Name="gearbox" Type="String" />
                        <asp:Parameter Name="price" Type="Decimal" />
                        <asp:Parameter Name="country_code" Type="String" />
                        <asp:Parameter Name="location_city" Type="String" />
                        <asp:Parameter Name="climate_control" Type="Int32" />
                        <asp:Parameter Name="seat_count" Type="Int32" />
                        <asp:Parameter Name="color" Type="String" />
                        <asp:Parameter Name="door_count" Type="Int32" />
                        <asp:Parameter Name="Auxiliary_heating" Type="Boolean" />
                        <asp:Parameter Name="Central_locking" Type="Boolean" />
                        <asp:Parameter Name="Cruise_control" Type="Boolean" />
                        <asp:Parameter Name="Electric_heated" Type="Boolean" />
                        <asp:Parameter Name="Electric_windows" Type="Int16" />
                        <asp:Parameter Name="Leather_seats" Type="Int16" />
                        <asp:Parameter Name="Parking_sensors" Type="Int16" />
                        <asp:Parameter Name="Power_Steering" Type="Int16" />
                        <asp:Parameter Name="Sunroof" Type="Int16" />
                        <asp:Parameter Name="Four_wheel_drive" Type="Int16" />
                        <asp:Parameter Name="Immobilizer" Type="Int16" />
                        <asp:Parameter Name="Xenon_headlights" Type="Int16" />
                        <asp:Parameter Name="ABS" Type="Int16" />
                        <asp:Parameter Name="ESP" Type="Int16" />
                        <asp:Parameter Name="user_comments" Type="String" />
                        <asp:Parameter Name="id" Type="Int32" />
                    </UpdateParameters>
                </asp:SqlDataSource>
           
</asp:Content>
